/* Global Styles
   ========================================================================== */

table.box-error {
	@extend .container;
	background: $alert-danger-bg !important;
	border: 1px solid #A90300;
	color: #FFFFFF;
	display: block;
	margin: 15px auto;

	@include border-radius($border-radius-base);

	.errorBox {
		padding: 15px;
	}
}

table.box-warning {
	@extend .container;
	background: #D500F9 !important;
	border: 1px solid #D500F9;
	color: #FFFFFF;
	margin: 15px auto;

	.warningBox {
		padding: 15px;
	}
}

// products display glyphicon
// if no image found

.no-image {
	max-width: 160px;
	margin: 0 auto;

	.product-image {
		@include no-image-bg();
		@include border-radius();
		padding: 0 15px;

		.glyphicon-picture,
		.fa-picture-o {
			font-size: 80px;
			line-height: 130px;
			text-align: center;
			width: 100%;
		}

		a, a:hover {
			color: inherit;
		}
	}
}

// image responsive fix
// needed for firefox and older IEs

.img-responsive-fix {
	width: 100%;
}

// icons
// copy/paste from /css/fontello-html/assets/styles/legacy/gm.css
// use this to attach icons to elements as :before

.gm-icon-before {
	font-family: "gm";
	font-style: normal;
	font-weight: normal;
	speak: none;
	display: inline-block;
	text-decoration: inherit;
	width: 1em;
	margin-right: .2em;
	text-align: center;
	font-variant: normal;
	text-transform: none;
	line-height: 1em;
	margin-left: .2em;
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
}

// buttons

.btn {

	text-transform: uppercase;
	letter-spacing: 1px;

	// unset for dropdown-toggles
	&.dropdown-toggle {
		text-transform: none;
		letter-spacing: 0;
	}

	&:focus {
		outline: none;
	}
}

// headlines

h1, h2, h3 {
	border-bottom: 3px solid $gx-headline-border-color;
	padding-bottom: 13px;
	margin-bottom: 30px;

	&.no-underline {
		border-bottom: none;
		margin-bottom: $line-height-base;
		padding-bottom: 0;
	}
}

// selection styling

::selection {
	background: $brand-primary; /* WebKit/Blink Browsers */
	color: #FFFFFF;
}

::-moz-selection {
	background: $brand-primary; /* Gecko Browsers */
	color: #FFFFFF;
}

// address blocks

address {
	font-style: italic;
	font-weight: bold;
}

// additional text styles

.text-bold {
	font-weight: bold;
}

.text-small {
	font-size: 11px;
}

// reset ul lists
.list-reset {
	@include reset-list();
}

// alerts
.alert {
	border: none;
	
	// alert boxes with checkboxes
	// overwrite .checkbox definition
	.checkbox {
		padding-top: floor($grid-gutter-width / 2)
	}
}

// indention classes

@for $i from 0 through 4 {
	.indent-#{$i} {
		padding-left: floor($i * $grid-gutter-width + 15);
	}
}

// indention classes
// for each breakpoint

@mixin make-indent($breakpoint, $pixels) {
	@media (min-width: $pixels) {
		@for $i from 0 through 4 {
			.indent-#{$breakpoint}-#{$i} {
				padding-left: floor($i * $grid-gutter-width + 15);
			}
		}
	}
}

@include make-indent(xs, $screen-xs-min);
@include make-indent(sm, $screen-sm-min);
@include make-indent(md, $screen-md-min);
@include make-indent(lg, $screen-lg-min);

// vertical spacing classes

@for $i from 0 through 4 {
	.space-#{$i} {
		margin-bottom: floor($i * $grid-gutter-width);
	}
}

// Cross browser vertical image alignment.
// http://stackoverflow.com/a/7310398
.align-helper {
	height: 100%;
	display: inline-block;
	vertical-align: middle;
}

// Remove ouline css styling from links.
a:focus {
	outline: none;
}

a {
    #main & {
        font-weight: $link-font-weight;
    }
    
    #breadcrumb_navi & {
        font-weight: normal;
    }
}

// TODO Move to correct position
body:not(.filterbox-enabled) .productlisting-filter-container .filter-button {
	display: none;
}

.noscript-notice {
	left: 0;
	margin: 0;
	position: fixed;
	top: 0;
	width: 100%;
	z-index: 3;
}

.hyphenate {
	hyphens: auto;
	-ms-hyphens: auto;
	-moz-hyphens: auto;
	-webkit-hyphens: auto;
}

// colored bar below headline
.malibu-heading {
	text-align: center;
	position: relative;
	padding-bottom: 10px;
	text-transform: uppercase;
	font-weight: 400;
	&:after {
		content: "";
		position: absolute;
		width: 50px;
		height: 2px;
		background-color: $gx-tab-border-color;
		bottom: 0;
		left: 50%;
		margin-left: -25px;
	}
}

// reset headline underlines and apply malibu heading
h1, h2, h3 {
	border-bottom: none;
	padding-bottom: 0;
	body.page-index #main &,
	.product-info-listings & ,
	.page-index-type-cat & {
		@extend .malibu-heading;
		&:after {
			background-color: $gx-headline-border-color;
		}
	}
}

// more margin for headlines on startpage
body.page-index #main {
	h2 {
		margin-bottom: 45px;
	}
}

.productlist-swiper,
.productlist-viewmode-grid {
	.product-container {
		.product-tile {
			figure {
				&.no-image {
					.product-image {
						vertical-align: middle;
					}
				}
			}
		}
	}
}

.product-container.flyover {
	.product-tile {
		figure {
			&.no-image {
				.product-image {
					vertical-align: middle;
				}
			}
		}
	}
}

.productlist-viewmode-list .product-container .inside .content-container .content-container-inner .image.no-image {
	display: table;
	width: 100%;
	.product-image {
		display: table-cell;
	}
}

select.form-control {
	-moz-appearance: none;
	-webkit-appearance: none;
	appearance: none;
	cursor: pointer;
	background-position: right 50%;
	background-repeat: no-repeat;
	background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA4AAAAMCAYAAABSgIzaAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyJpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuMC1jMDYwIDYxLjEzNDc3NywgMjAxMC8wMi8xMi0xNzozMjowMCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENTNSBNYWNpbnRvc2giIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6NDZFNDEwNjlGNzFEMTFFMkJEQ0VDRTM1N0RCMzMyMkIiIHhtcE1NOkRvY3VtZW50SUQ9InhtcC5kaWQ6NDZFNDEwNkFGNzFEMTFFMkJEQ0VDRTM1N0RCMzMyMkIiPiA8eG1wTU06RGVyaXZlZEZyb20gc3RSZWY6aW5zdGFuY2VJRD0ieG1wLmlpZDo0NkU0MTA2N0Y3MUQxMUUyQkRDRUNFMzU3REIzMzIyQiIgc3RSZWY6ZG9jdW1lbnRJRD0ieG1wLmRpZDo0NkU0MTA2OEY3MUQxMUUyQkRDRUNFMzU3REIzMzIyQiIvPiA8L3JkZjpEZXNjcmlwdGlvbj4gPC9yZGY6UkRGPiA8L3g6eG1wbWV0YT4gPD94cGFja2V0IGVuZD0iciI/PuGsgwQAAAA5SURBVHjaYvz//z8DOYCJgUxAf42MQIzTk0D/M+KzkRGPoQSdykiKJrBGpOhgJFYTWNEIiEeAAAMAzNENEOH+do8AAAAASUVORK5CYII=);
	// padding: .5em;
	padding-right: 1.5em;
	&::-ms-expand {
		display: none;
	}
}

.input-group-addon {
	background-color: transparent;
	border-width: 0;
}

// big property selectboxes
.form-group-big-select {
	position: relative;
	background-color: white;
	.control-label {
		position: absolute;
		top: 9px;
		right: 0;
		left: 0;
		padding: 0 $padding-base-horizontal;
		z-index: 2;
		font-size: ($font-size-base - 2px);
		pointer-events: none;
	}
	.form-control {
		-moz-appearance: none;
		-webkit-appearance: none;
		appearance: none;
		height: ($input-height-base + 20px);
		padding-top: ($padding-base-vertical + 15px);
		cursor: pointer;
		position: relative;
		z-index: 1;
		background-color: transparent;
		background-image: none;
		font-size: $font-size-large;
		&::-ms-expand {
			display: none;
		}
	}
	.help-block {
		display: none;
	}
	svg {
		position: absolute;
		right: $padding-base-horizontal;
		bottom: 16px;
		z-index: 2;
		width: 16px;
		pointer-events: none;
		path {
			fill: $gray-light;
		}
	}
}

.navbar-topbar,
.navbar-secondary {
	ul.dropdown-menu {
		li {
			.form-group {
				padding-right: 0;
				padding-left: 0;
			}
		}
	}
}

* {
    &:not(input, textarea, select) {
        &:focus-visible {
            @include element-focus;
        }
    }
}

.navbar-default {
    .navbar-brand {
        &:focus-visible {
            @include element-focus;
        }
    }
}